-- GENERATED SPELL FOR [Dark Iron Shadowcaster] --


function spell0_2577(pUnit, Event) --@Immolate,n/a--
pUnit:FullCastSpellOnTarget(2941,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_2577', 17000, 1)
end

function spell1_2577(pUnit, Event) --@Shadow Bolt,n/a--
pUnit:FullCastSpellOnTarget(20816,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_2577', 3000, 1)
end

function Sorts_2577(pUnit, Event)
local choix_sorts_2577 = math.random(0, 1)
if choix_sorts_2577 == 0 then
pUnit:RegisterEvent('spell0_2577', 1, 1)
end
if choix_sorts_2577 == 1 then
pUnit:RegisterEvent('spell1_2577', 1, 1)
end
end

function mob2577_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_2577', math.random(1500, 3000), 1)
end

function mob2577_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2577_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob2577_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(2577, 1, 'mob2577_Action')
RegisterUnitEvent(2577, 2, 'mob2577_Leave')
RegisterUnitEvent(2577, 3, 'mob2577_Kill')
RegisterUnitEvent(2577, 4, 'mob2577_Die')
